package org.example.feign;

import org.example.domain.Prod;
import org.example.feign.sentinel.SeckillProdFeignSentinel;
import org.example.model.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "product-service", contextId = "seckillProdClient", fallback = SeckillProdFeignSentinel.class)
public interface SeckillProdFeign {

    @GetMapping("/prod/prod/getSeckillProdByProdIds")
    public Result<List<Prod>> getSeckillProdByProdIds(@RequestParam List<Long> prodIds);

}
